package View;
import java.util.Collection;
import model.Cell;
import model.Game;

public class GameView {

	private Game game;

	public GameView(Game game) {
		this.game = game;
	}
	
	public void show(){
		Collection<Cell> cells = game.getCells();
		int column = 0;
		String output = "";
		for (Cell cell : cells) {
			if (cell.isAlive()){
				output += "A";  //Could have made a CellView class, but this is so small it felt ridiculous
			}
			else{
				output += "-";
			}
			column++;
			if (column >= game.getLenght()) {
				column = 0;
				System.out.println(output);
				output = "";
			}
		}
	}
}
